home *** CD-ROM | disk | FTP | other *** search
/ The CICA Windows Explosion! / The CICA Windows Explosion! - Disc 1.iso / games / fibsw130.zip / UNIXB.SCC < prev    next >
Text File  |  1994-05-31  |  3KB  |  94 lines

  1. @echo 0 ;%%Generic UNIX dial-up host with Bourne (sh) command shell.
  2. @rem ****************************************************************************
  3. @rem ****                                                                   *****
  4. @rem ****     UNIX bourne shell login Script                                *****
  5. @rem ****        Assumes that csh is the default command shell              *****
  6. @rem ****                                                                   *****
  7. @rem ****************************************************************************
  8.  
  9. @echo "\r\n** Connecting to FIBS via UNIX Host (command shell: sh) **\r\n"
  10. @board 0
  11.  
  12. @rem *****************************************************
  13. @rem ***  Dial the Telephone Number                     **
  14. @rem *****************************************************
  15.  
  16.  
  17. @rem Execute dial.scr file to dial the telephone number.
  18. <dial.scr
  19.  
  20.  
  21. @rem *****************************************************
  22. @rem ***  Execute the login procedure                   **
  23. @rem *****************************************************
  24.  
  25. @if "%HostLoginName%" != ""
  26. @:RetryLogin
  27. @   if "%NetworkScript%" == "manual.scn" ; No prompts or timeouts during manual network connect
  28. @       wait "ogin:"
  29. @   else 
  30. @       echo "\r\n** Logging in...\r\n"
  31. @       if not @wait "ogin:" 10     ; e.g. "login:", or "Login:" &c.
  32. @           echo "\r\n** Error(unixb.scc): error - Host Login Prompt not received\r\n"
  33. @           send "\r"
  34. @           goto RetryLogin
  35. @       endif
  36. @   endif
  37. @   send "%HostLoginName%\r"
  38. @   if not @wait "\n" 10
  39. @      echo "\r\n** Error(unixb.scc): No response to Host Login Name\r\n"
  40. <
  41. @   endif
  42. @   if "%HostPassword%" != ""
  43. @       if not @wait "assword:" 30  ; e.g. "Password:" or "password:"
  44. @           echo "\r\n** Error(unixb.scc): Host Password prompt not received\r\n"
  45. <
  46. @       endif
  47. @       send "%HostPassword%\r"
  48. @       if not @wait "\n" 10
  49. @           echo "\r\n** Error(unixb.scc): No response to Host Password\r\n"
  50. <
  51. @       endif
  52. @   else
  53. @       rem ** We need to synchronize around the password **
  54. @       echo "\r\n** Automated login script will resume after you enter your password\r\n"
  55. @       if not @wait "assword:" 30
  56. @          echo "\r\n** Error(unixb.scc): Host password prompt not received\r\n"
  57. <
  58. @       endif
  59. @       passwordEntry 1
  60. @       wait "\n" 
  61. @       passwordEntry 0
  62. @   endif ; HostPassword
  63. @else 
  64. @   if "%NetworkScript%" != "manual.scn" ; no prompts during manual network connect
  65. @       echo "\r\n** Automated login script will resume after login is complete\r\n"
  66. @   endif
  67. @   wait "ogin:"
  68. @   wait "assword:"
  69. @   passwordEntry 1
  70. @   wait "\n"
  71. @   passwordEntry 0
  72. @endif ; HostLoginName
  73.  
  74. @rem *****************************************************
  75. @rem *** Wait for the command shell prompt             ***
  76. @rem *****************************************************
  77.  
  78. @rem This section assumes that (1) login shell is sh, not csh (2) '$' does not occur in the motd (heaven forbid@)
  79. @rem Change '%' to '\%' if your login shell is csh
  80.  
  81. @echo "\r\n*** Waiting for shell command prompt...\r\n"
  82. @if not @wait "$"  ; Wait indefinitely
  83. @   echo "\r\n*** Error(unixb.scc): Command shell prompt not found\r\n"
  84. <
  85. @endif
  86.  
  87.  
  88. @rem *****************************************************
  89. @rem *** Connect via telnet                            ***
  90. @rem *****************************************************
  91.  
  92. <telnet.scr
  93.  
  94.